package com.xp.dto.flow;

import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;

/**
 * 流程执行记录DTO
 * 
 * @author xp
 * @since 2025-01-01
 */
@Data
@Schema(description = "流程执行记录DTO")
public class FlowExecutionDTO {

    @Schema(description = "主键ID")
    private Long id;

    @Schema(description = "执行ID")
    private String executionId;

    @Schema(description = "流程编码")
    private String flowCode;

    @Schema(description = "流程版本")
    private String flowVersion;

    @Schema(description = "输入数据（JSON）")
    private String inputData;

    @Schema(description = "输出数据（JSON）")
    private String outputData;

    @Schema(description = "执行状态")
    private String status;

    @Schema(description = "开始时间")
    private LocalDateTime startTime;

    @Schema(description = "结束时间")
    private LocalDateTime endTime;

    @Schema(description = "执行时长（毫秒）")
    private Long duration;

    @Schema(description = "错误信息")
    private String errorMessage;

    @Schema(description = "链路追踪ID")
    private String traceId;

    @Schema(description = "执行人ID")
    private Long creatorId;

    @Schema(description = "创建时间")
    private LocalDateTime createTime;

    @Schema(description = "更新时间")
    private LocalDateTime updateTime;

    @Schema(description = "创建者")
    private String createBy;

    @Schema(description = "更新者")
    private String updateBy;
}